package org.jsola.hr.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;
import org.jsola.core.dto.BaseDTO;

import java.math.BigDecimal;
import javax.validation.constraints.NotNull;

import static org.jsola.hr.example.AttendanceDataTempExample.E_ATTENDANCE_DATA_RECORD_ID;
import static org.jsola.hr.example.AttendanceDataTempExample.E_EMP_ID;
import static org.jsola.hr.example.AttendanceDataTempExample.E_EMP_NAME;
import static org.jsola.hr.example.AttendanceDataTempExample.E_EMP_PHONE;
import static org.jsola.hr.example.AttendanceDataTempExample.E_ERROR_COL;
import static org.jsola.hr.example.AttendanceDataTempExample.E_ERROR_REASON;
import static org.jsola.hr.example.AttendanceDataTempExample.E_IS_ERROR;
import static org.jsola.hr.example.AttendanceDataTempExample.E_IS_HANDLE;
import static org.jsola.hr.example.AttendanceDataTempExample.E_MONTH;
import static org.jsola.hr.example.AttendanceDataTempExample.E_SALLARY_IMPACT;
import static org.jsola.hr.example.AttendanceDataTempExample.E_SORT;
import static org.jsola.hr.example.AttendanceDataTempExample.E_VALUE;
import static org.jsola.hr.example.AttendanceDataTempExample.E_WORKING_HOURS;
import static org.jsola.hr.example.AttendanceDataTempExample.E_YEAR;
import static org.jsola.hr.example.AttendanceDataTempExample.M_ATTENDANCE_DATA_RECORD_ID_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.M_ATTENDANCE_DATA_RECORD_ID_NOT_NULL;
import static org.jsola.hr.example.AttendanceDataTempExample.M_EMP_ID_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.M_EMP_NAME_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.M_EMP_PHONE_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.M_ERROR_COL_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.M_ERROR_REASON_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.M_VALUE_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.M_WORKING_HOURS_MAX;
import static org.jsola.hr.example.AttendanceDataTempExample.N_ATTENDANCE_DATA_RECORD_ID;
import static org.jsola.hr.example.AttendanceDataTempExample.N_EMP_ID;
import static org.jsola.hr.example.AttendanceDataTempExample.N_EMP_NAME;
import static org.jsola.hr.example.AttendanceDataTempExample.N_EMP_PHONE;
import static org.jsola.hr.example.AttendanceDataTempExample.N_ERROR_COL;
import static org.jsola.hr.example.AttendanceDataTempExample.N_ERROR_REASON;
import static org.jsola.hr.example.AttendanceDataTempExample.N_IS_ERROR;
import static org.jsola.hr.example.AttendanceDataTempExample.N_IS_HANDLE;
import static org.jsola.hr.example.AttendanceDataTempExample.N_MONTH;
import static org.jsola.hr.example.AttendanceDataTempExample.N_SALLARY_IMPACT;
import static org.jsola.hr.example.AttendanceDataTempExample.N_SORT;
import static org.jsola.hr.example.AttendanceDataTempExample.N_VALUE;
import static org.jsola.hr.example.AttendanceDataTempExample.N_WORKING_HOURS;
import static org.jsola.hr.example.AttendanceDataTempExample.N_YEAR;

/**
 * 临时考勤数据
 *
 * @author zhr
 */
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "新增【临时考勤数据】的参数")
@Data
public class AttendanceDataTempAddDTO extends BaseDTO {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(notes = N_WORKING_HOURS, example = E_WORKING_HOURS)
    @Length(max = 200, message = M_WORKING_HOURS_MAX)
    private String workingHours;

    @ApiModelProperty(notes = N_ERROR_COL, example = E_ERROR_COL)
    @Length(max = 200, message = M_ERROR_COL_MAX)
    private String errorCol;

    @ApiModelProperty(notes = N_ATTENDANCE_DATA_RECORD_ID, example = E_ATTENDANCE_DATA_RECORD_ID, required = true)
    @NotNull(message = M_ATTENDANCE_DATA_RECORD_ID_NOT_NULL)
    @Length(max = 32, message = M_ATTENDANCE_DATA_RECORD_ID_MAX)
    private String attendanceDataRecordId;

    @ApiModelProperty(notes = N_VALUE, example = E_VALUE)
    @Length(max = 3000, message = M_VALUE_MAX)
    private String value;

    @ApiModelProperty(notes = N_IS_ERROR, example = E_IS_ERROR)
    private Boolean isError;

    @ApiModelProperty(notes = N_IS_HANDLE, example = E_IS_HANDLE)
    private Boolean isHandle;

    @ApiModelProperty(notes = N_SORT, example = E_SORT)
    private Integer sort;

    @ApiModelProperty(notes = N_EMP_ID, example = E_EMP_ID)
    @Length(max = 32, message = M_EMP_ID_MAX)
    private String empId;

    @ApiModelProperty(notes = N_EMP_NAME, example = E_EMP_NAME)
    @Length(max = 32, message = M_EMP_NAME_MAX)
    private String empName;

    @ApiModelProperty(notes = N_EMP_PHONE, example = E_EMP_PHONE)
    @Length(max = 32, message = M_EMP_PHONE_MAX)
    private String empPhone;

    @ApiModelProperty(notes = N_YEAR, example = E_YEAR)
    private Integer year;

    @ApiModelProperty(notes = N_MONTH, example = E_MONTH)
    private Integer month;

    @ApiModelProperty(notes = N_SALLARY_IMPACT, example = E_SALLARY_IMPACT)
    private BigDecimal sallaryImpact;

    @ApiModelProperty(notes = N_ERROR_REASON, example = E_ERROR_REASON)
    @Length(max = 32, message = M_ERROR_REASON_MAX)
    private String errorReason;


}

